package com.cxs.musicplaywidget.view;

import com.cxs.musicplaywidget.data.EventParam;
import com.cxs.musicplaywidget.data.MDevice;
import com.cxs.musicplaywidget.data.PlayerControl;
import com.cxs.musicplaywidget.player.data.MusicInfo;

import java.util.List;

/**
 * @ClassName IControllerAdapter
 * @Author cxs
 * @Version 1.0
 * @Description TODO
 * @Date 2022/03/10
 */
public interface IControllerAdapter {

    /**
     * 判断指定索引的设备是否已连接
     * @param deviceIndex
     * @return
     */
    boolean isConnected(byte deviceIndex);
    /**
     * 更新设备列表
     * @param reload
     */
    void updateDeviceList(boolean reload);

    /**
     * 更新控制按钮状态
     * @param playerState
     */
    void updatePlayerControl(EventParam.PlayerState playerState);

    /**
     * 更新播放列表
     * @param eventParam
     */
    void updatePlaylist(EventParam eventParam);

    /**
     * 更新歌曲信息
     * @param musicInfo
     */
    void updateMusicInfo(MusicInfo musicInfo);

    void updateVolume(int max, int vol);

    void updateThumbnail(byte[] thumbnail, int index);
}
